package net.blogways.ordermgr.util;

import java.util.Arrays;
import java.util.List;

@SuppressWarnings("CheckStyle")
public interface Constants {

  /**
   * 数据源
   */
  String DATABASE_CEN = "cen";
  String DATABASE_INFO_F = "info1";
  String DATABASE_INFO_S = "info2";
  String DATABASE_TICKET = "ticket";

  /**
   * 邮件ID生成规则.
   */
  String MAIL_NOTICE_ID = "MAIL_NOTICE_ID:18";

  /**
   * 邮件信息表.
   */
  public static final String TI_O_MAIL = "TI_O_MAIL";

  /**
   * 插入邮件信息ref.
   */
  public static final String INSERT_TI_O_MAIL = "INSERT_TI_O_MAIL";

  /**
   * 批量操作订单表ID生成规则.
   */
  String SUBSCRIBE_BAT_ID_RULE = "SUBSCRIBE_ID:18,FILE_ID:8";

  /**
   * 操作参数表表名.
   */
  String OPERATE_PARAMS_TABLE = "TD_S_OPERATE";

  /**
   * 通用查询语句SQL_REF.
   */
  String SEL_FROM_BY_PK = "SEL_FROM_BY_PK";

  /**
   * MongoDB metadata 集合
   */
  static final String FS_METADATA_NAME = "fs.files";

  /**
   * MongoDB文件可用时，删除标记对应的值.
   */
  static final int AVAILABLE = 0;

  /**
   * MongoDB文件可用时，删除标记对应的值.
   */
  static final int DISABLED = 1;

  /**
   * 换行符正则
   */
  String LINE_BREAK = "(\\r\\n|\\r|\\n|\\n\\r)";

  /**
   * mysql dual
   */
  String DUAL = "DUAL";

  /**
   * mysql current time sql_ref
   */
  String CURRENT_TIME = "CURRENT_TIME";

  /**
   * 通用操作语句SQL_REF.
   */
  List<String> SQL_REF_COMMON = Arrays.asList("INT_COMMON", "DEL_FROM_BY_PK", "UPD_COMMON");

  /**
   * 公用变更状态标识为成功SQL_REF.
   */
  String SUCCESS_SQL_REF = "SUCCESS";

  /**
   * 分页
   */
  int PAGE_SIZE = 500;

  /**
   * CDR_TABLE_NAME.
   */
  String CDR_TABLE_NAME = ":CDR_TABLE_NAME";

  /**
   * TABLE_NAME.
   */
  String TABLE_NAME_CDR = "CDR_TABLE_NAME";

  /**
   * 主键生成流程.
   */
  String GET_TICKET_LCU = "tcs.common:getTicketFlow";

  /**
   * 用户锁定状态：0.未锁定，1.锁定
   */
  String USER_UNLOCKED = "0";
  String USER_LOCKED = "1";

  /**
   * 文件格式.
   */
  List<String> FILE_TYPE = Arrays.asList("PNG", "JPG", "JPEG", "PDF");


  /**
   * 订单状态
   */
  String ORDER_STATE_AUDITING = "1";
  String ORDER_STATE_UNAUDITED = "2";
  String ORDER_STATE_DRAFT = "0";
  String ORDER_STATE_TOBE_PROD = "3";
  String ORDER_STATE_CONFIRMED = "4";//确认生产

  /**
   * 0-拖鞋,1-软管洗护,2-瓶装洗护,3-香皂,4-包装干货,5-自定义
   */
  String SLIPPER_CODE = "0";
  String HOSEWASH_CODE = "1";
  String BOTTLEDWASH_CODE = "2";
  String SOAP_CODE = "3";
  String DRY_CODE = "4";
  String CUSTOM_CODE = "5";

  /**
   * 订单类目
   */
  String ORDER_SLIPPER = "order_slipper";
  String ORDER_SOAP = "order_soap";
  String ORDER_HOSEWASH = "order_hosewash";
  String ORDER_BOTTLEDWASH = "order_bottled_wash";
  String ORDER_DRY = "order_dry";
  String ORDER_CUSTOM = "order_custom";
}
